<?php
/**
 * Document_Interface
 * @filesource
 */
/**
 * Namespace
 */
namespace framework\library\interfaces;
/**
 * Dependencies
 */
/**
 * Contains the data necessary to provide a basic document structure that includes
 * a DOCTYPE, HTML, HEAD and BODY tags
 * 
 * Provides methods for adding stylesheets, javascript files, etc. to the document.
 * 
 * Extends Response only to provide a convenience when writing controllers. These 
 * classes do not need to be coupled.
 * 
 * @author Randy Casburn <randy@plurious.com>
 * @copyright Copyright Plurious Software, all rights reserved
 * @license MIT
 * @license http://www.opensource.org/licenses/mit-license.html
 * @link http://plurious.com/framework/documentation/classes/Front.html
 * @version 2.1
 * @api
 */
interface Document_Interface {

    /**
     * Sets the page title (for the title bar)
     * 
     * @param string $title 
     */
    public function setTitle($title);

    /**
     * Sets the description for the header meta tag
     * 
     * @param string $description 
     */
    public function setDescription($description);

    /**
     * Sets the keywords for the header meta tag
     * 
     * @param string $description 
     */
    public function setKeywords($keywords);

    /**
     * Sets the links for the header rel tag
     * 
     * @param string $description 
     */
    public function addLink($href, $rel);

    /**
     * Sets stylesheet information to add to document as a rel stylesheet link
     * 
     * @param string $href
     * @param string $rel
     * @param string $media 
     */
    public function addStyle($href, $rel = 'stylesheet', $media = 'screen');

    /**
     * Sets javascript inforamtion to add to document as a script tag src
     * 
     * @param string $script 
     */
    public function addScript($script);

    /**
     * Sets raw script text to inserted in document just prior to closing body tag
     * 
     * @param string $scriptText 
     */
    public function addInPageScript($scriptText);

    /**
     * Sets the page content that will be placed between the body tags
     * 
     * This is the main page content
     * 
     * @param string $content 
     */
    public function setContent($content);
    /*
      public function getTitle() {
      return $this->title;
      }

      public function getDescription() {
      return $this->description;
      }

      public function getKeywords() {
      return $this->keywords;
      }

      public function getLinks() {
      return $this->links;
      }

      public function getStyles() {
      return $this->styles;
      }

      public function getScripts() {
      return $this->scripts;
      }
     */

    /**
     * Document is rendered as final page construction task
     * 
     * Applies the page content to the document template.
     *
     * @uses document.tpl Mandatory template file located in the layout directory or default layout directory
     * @uses Front
     * @uses Registry
     * @uses Config
     * @param string $output 
     * @param string $type accepts: document[default], json, rss2.0, atom
     */
    public function renderFinal($output, $type);
}

?>